<?php
/**
 * User: YL
 * Date: 2019/09/12
 */

namespace App\Common\Models;

use App\Common\ConstAttribute;
use Illuminate\Database\Eloquent\Model;
use restful\traits\RestfulModel;

/**
 * @method RestfulModel initialize()
 */
class BaseModel extends Model implements ConstAttribute
{
    use RestfulModel;

    protected function initializeBefore()
    {
        // 设置当前表名
        $this->setTable(static::getSnakePluralName());
    }
}
